<!DOCTYPE html>
<html>
<head>
	<meta charset="utf-8">
	<meta http-equiv="X-UA-Compatible" content="IE=edge" />
	<meta name="viewport" content="width=device-width, initial-scale=1" />
	<title>{$_title}{$_config['web_title'] ? ('-' . $_config['web_title']) : ''}</title>
	<meta name="keywords" content="{$_config['web_keywords']}" />
	<meta name="description" content="{$_config['web_description']}" />
	<meta name="renderer" content="webkit">
	
	<link rel="stylesheet" type="text/css" href="../public/css/style.css?v={$_config['web_version']}" />

	<script type="text/javascript" src="__PUBLIC__js/jquery-1.12.4.min.js"></script>
	<script type="text/javascript" src="__PUBLIC__js/jquery-plugin/jquery.md5.js"></script>
	<script type="text/javascript" src="../public/js/common.js?v={$_config['web_version']}"></script>

	<link rel="stylesheet" type="text/css" href="__PUBLIC__js/jquery-ui/jquery-ui.min.css" />
	<script type="text/javascript" src="__PUBLIC__js/jquery-ui/jquery-ui.min.js"></script>

	<link href="__PUBLIC__js/bootstrap/css/bootstrap.css" rel="stylesheet">
	<script src="__PUBLIC__js/bootstrap/js/bootstrap.js"></script>
</head>
<body>
<script type="text/javascript">
	var _version = "{$_config['web_version']}";

	$(document).ready(function () {
		$('.navbar-form').submit(function () {
			if(!$('.keyword').val()){
				
				return false;
			}
		})
	});
</script>
<div class="navbar navbar-fixed-top">
	<div class="container">
		<div class="logo">
			<a href="{:url('/')}"><i class="icon-logo"></i><span class="title"></span></a>
		</div>
		<form class="navbar-form navbar-left" action="{:url('Search/index')}" method="get" novalidate="true">
			<div class="input-group">
				<input type="text" name="keyword" class="keyword form-control" placeholder="搜索你感兴趣的内容..." autocomplete="off" style="padding-right: 40px;">
				<button type="submit" class="input-group-addon btn"><span id="search-button" class="glyphicon glyphicon-search" aria-hidden="true"></span></button>
			</div>
		</form>
		<ul class="menu">
			<li class="{$controller_name == 'Question' ? 'on' : ''}"><a href="{:url('Question/index')}">问答</a></li>
			<li class="{$controller_name == 'Article' ? 'on' : ''}"><a href="{:url('Article/index')}">文章</a></li>
			<li class="{$controller_name == 'Index' ? 'on' : ''}"><a href="{:url('Index/software')}" style="color: #ff6e32;">免费财务软件</a></li>
			<li class="{in name='module' value='help,operate'}on{/in}"><a href="{:url('Help/index', array('module' => 'help'))}">常见问题</a></li>
			<li class="{$module == 'about_us' ? 'on' : ''}"><a href="{:url('Page/index', array('module' => 'about_us'))}">关于我们</a></li>
		</ul>
		<div class="user-info btn-group">
			{eq name="_user_id" value="0"}
				<a href="{:url('Login/index')}">登录/注册</a>
			{else/}
				<div class="dropdown" style="float: left">
					<a href="{:url('People/question', array('user_id' => $_user_id))}" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-expanded="true">
						<img src="{:img($_user_head_url, 100, 100)}">
						<span class="user-name">{$_user_show_name}</span>
						{gt name="_user_message_num" value="0"}
							<span class="label label-danger">{$_user_message_num}</span>
						{/gt}
					</a>
					<ul class="dropdown-menu dropdown-menu-right" role="menu">
						<li><a href="{:url('People/question', array('user_id' => $_user_id))}">我的主页</a></li>
						<li><a href="{:url('People/message', array('user_id' => $_user_id))}">消息({$_user_message_num})</a></li>
						<li><a href="{:url('UserSetting/index')}">账号设置</a></li>
						<li class="divider"></li>
						<li><a href="{:url('User/logout')}">退出</a></li>
					</ul>
				</div>
			{/eq}
		</div>
	</div>
</div>
<div class="top-alert clearfix text-center" style="margin-top: 50px;">
<!--[if lt IE 9]>
	<div class="alert alert-danger topframe" role="alert">你的浏览器实在<strong>太旧了</strong>，请升级完浏览器再说
		<a target="_blank" class="alert-link" href="http://browsehappy.com">立即升级</a>
	</div>
<![endif]-->
</div>